import component from 'element-plus/es/components/tree-select/src/tree-select-option.mjs'
import {createRouter,createWebHistory} from 'vue-router'

const routes = [
	{
	  path: '',
	  name: 'index',
		redirect:"/Login",
	},
	{
	  path: '/login',
	  name: 'login',
	  component: () => import('../views/Login.vue')
	},
	{
		path: '/home',
		name: 'home',
	    redirect:"/welcome",
		component: () => import('../views/home.vue'),
		meta:"1",
		children: [{
			path: '/welcome',
			name: 'welcome',
			component: () => import('../views/welcome.vue'),
		}, 
		{
			path:'/user',
			name:'userinfo',
			component:()=>import('../views/userinfo/index.vue')
		},
		{
			path:'/menu',
			name:'menuinfo',
			component:()=>import('../views/menuinfo/index.vue')
		},
		{
			path:'/role',
			name:'roleinfo',
			component:()=>import('../views/roleinfo/index.vue')
		},
		{
			path:'/dict',
			name:'dictinfo',
			component:()=>import('../views/dictinfo/index.vue')
		},		
		{
			path:'/business',
			name:'businessInfo',
			component:()=>import('../views/businessInfo/index.vue')
		}
,		
		{
			path:'/procedure',
			name:'procedure',
			component:()=>import('../views/procedureinfo/index.vue')
		},
		{
			path:'/order',
			name:'order',
			component:()=>import('../views/orderinfo/index.vue')
		},
		{
			path:'/myOrder',
			name:'myOrder',
			component:()=>import('../views/orderinfo/MyOrder.vue')
		},
		{
			path:'/myOrderApproval',
			name:'myOrderApproval',
			component:()=>import('../views/orderinfo/MyApproval.vue')
		},
		{
			path:'/productinfo',
			name:'productinfo',
			component:()=>import('../views/productinfo/index.vue')
		},
		{
			path:'/Customer',
			name:'Customer',
			component:()=>import('../views/Customer/index.vue')
		},
		{
			path:'/project',
			name:'project',
			component:()=>import('../views/projectInfo/index.vue')
		},
		{
			path:'/myProject',
			name:'myProject',
			component:()=>import('../views/projectInfo/MyProject.vue')
		},
		{
			path:'/approval',
			name:'approval',
			component:()=>import('../views/approval/index.vue')
		},
		{
			path:'/myapproval',
			name:'myapproval',
			component:()=>import('../views/approvalNode/myapproval.vue')
		},
		{
			path:'/approvalNode',
			name:'approvalNode',
			component:()=>import('../views/approvalNode/index.vue')
		},
		{
			path:'/task',
			name:'task',
			component:()=>import('../views/task/index.vue')
		},
		{
			path:'/myTask',
			name:'myTask',
			component:()=>import('../views/task/myTask.vue')
		},
		{
			path:'/delay',
			name:'delay',
			component:()=>import('../views/delay/index.vue')
		},
		{
			path:'/delayApproval',
			name:'delayApproval',
			component:()=>import("../views/delay/MyApproval.vue")
		},
		{
			path:'/transfer',
			name:'transfer',
			component:()=>import('../views/transfer/index.vue')
		},
		{
			path:'/transferApproval',
			name:'transferApproval',
			component:()=>import("../views/transfer/MyApproval.vue")
		}
	]}
]



const router = createRouter({
	history: createWebHistory(),
	routes: routes
})

export default router